<template>
	<view class="iconfont icon-icon" @click="uploadImg">
	
	</view>
</template>

<script>
	import upLoadFile from '../../../utils/upLoadFile.js'
	import MyMessage from '../../../utils/MyMessage.js'
	
	export default {
		methods:{
			uploadImg() { //发送图片
				uni.chooseImage({
					count: 6,
					sizeType: ['original', 'compressed'],
					success:  (res) => {
						res.tempFilePaths.forEach(async(file)=>{
							var message= new MyMessage({accept_type:this.$store.state.chat.chatObjectInfo.chatObjectData.accept_type,type:2,content:file,ws:this.$store.state.chat.ws})
							message.addMessageList(message)
							
					
						})
						
					}
				})
			},
		}
	}
</script>

<style scoped>
	// border: 1px solid red;
	.iconfont {
		color: #07DC00;
		margin-left: 20rpx;
	
	}
	
	.icon-icon {
		font-size: 65rpx;
	}
</style>
